package org.glandais.birt.osgi.designer.impl;

import java.util.Properties;

import org.eclipse.datatools.connectivity.oda.design.ui.wizards.DataSourceWizardPage;
import org.eclipse.jface.resource.ImageDescriptor;
import org.eclipse.swt.widgets.Composite;

public class OSGiDataSourceWizardPage extends DataSourceWizardPage {

	private OSGiDataSourcePageHelper dataSourcePageHelper;

	public OSGiDataSourceWizardPage(String pageName, String title,
			ImageDescriptor titleImage) {
		super(pageName, title, titleImage);
		dataSourcePageHelper = new OSGiDataSourcePageHelper(this);
	}

	public OSGiDataSourceWizardPage(String pageName) {
		super(pageName);
		dataSourcePageHelper = new OSGiDataSourcePageHelper(this);
	}

	@Override
	public Properties collectCustomProperties() {
		return dataSourcePageHelper.collectCustomProperties();
	}

	@Override
	public void createPageCustomControl(Composite parent) {
		dataSourcePageHelper.createAndInitCustomControl(parent, null);
	}

	@Override
	public void setInitialProperties(Properties dataSourceProps) {
		dataSourcePageHelper.setInitialProperties(dataSourceProps);
	}

}
